/**
 * Description: 统一依赖管理
 */


object AndroidX {
    const val core_ktx = "androidx.core:core-ktx:${Versions.core_ktx}"
    const val appcompat = "androidx.appcompat:appcompat:${Versions.appcompat}"
    const val constraintLayout =
        "androidx.constraintlayout:constraintlayout:${Versions.constraintLayout}"
    const val pagingRuntime = "androidx.paging:paging-runtime:${Versions.paging}"
    const val annotation = "androidx.annotation:annotation:${Versions.annotation}"

    const val workTesting = "androidx.work:work-testing:${Versions.work}"


    const val androidx_work_runtime = "androidx.work:work-runtime:${Versions.androidx_work_version}"
    const val androidx_work_ktx = "androidx.work:work-runtime-ktx:${Versions.androidx_work_version}"

}

object CommonUI {
    const val swiperefreshlayout =
        "androidx.swiperefreshlayout:swiperefreshlayout:${Versions.swiperefreshlayout}"
    const val cardView = "androidx.cardview:cardview:${Versions.cardView}"
    const val recyclerview = "androidx.recyclerview:recyclerview:${Versions.recyclerview}"
}


object Kt {
    const val kotlin_stdlib = "org.jetbrains.kotlin:kotlin-stdlib-jdk7:${Versions.kotlin_version}"
    const val kotlinx_coroutines =
        "org.jetbrains.kotlinx:kotlinx-coroutines-core:${Versions.kotlinx_coroutines}"
    const val kotlinx_coroutines_android =
        "org.jetbrains.kotlinx:kotlinx-coroutines-android:${Versions.kotlinx_coroutines}"
}

object Retrofit {
    const val retrofit = "com.squareup.retrofit2:retrofit:${Versions.retrofit}"
    const val gson = "com.squareup.retrofit2:converter-gson:${Versions.retrofit}"
    const val adapter_rxjava2 = "com.squareup.retrofit2:adapter-rxjava2:${Versions.retrofit}"

    //数据持久化
    const val persistent_cookieJar = "com.github.franmontiel:PersistentCookieJar:v1.0.1"

    val retrofit_list = listOf(
        retrofit,
        gson,
        adapter_rxjava2,
        persistent_cookieJar
    )
}

object RxJava {
    const val rxjava = "io.reactivex.rxjava2:rxjava:${Versions.rxjava}"
    const val rxandroid2 = "io.reactivex.rxjava2:rxandroid:${Versions.rxandroid2}"
    const val rxandroid = "io.reactivex:rxandroid:${Versions.rxandroid}"

    const val autodispose = "com.uber.autodispose:autodispose:${Versions.autodispose}"
    const val autodispose_android_archcomponents =
        "com.uber.autodispose:autodispose-android-archcomponents:${Versions.autodispose}"

    //权限
    const val rxpermission = "com.github.tbruyelle:rxpermissions:${Versions.rxPermission}"
}

object Dependence {

    const val material = "com.google.android.material:material:${Versions.material}"
    const val google_gson = "com.google.code.gson:gson:${Versions.google_gson}"

    // glide
    const val glide = "com.github.bumptech.glide:glide:${Versions.glide}"

    //数据库存储
    const val android_data_storage =
        "xiaofei.library:android-data-storage:${Versions.android_data_storage}"

    //沉浸式状态栏
    const val immersionbar = "com.gyf.immersionbar:immersionbar:${Versions.immersionbar}"


    const val bottomNavigationBar = "com.github.ittianyu:BottomNavigationViewEx:2.0.4"

    /**通用适配器*/
    const val baseRecyclerViewAdapter =
        "com.github.CymChad:BaseRecyclerViewAdapterHelper:${Versions.baseRecyclerAdapter}"

    /**工具类合集*/
    const val utilcodex = "com.blankj:utilcodex:1.26.0"

    /** 騰訊的mmkv 替代sp  */
    const val mmkv = "com.tencent:mmkv:1.0.22"

    const val bugly = "com.tencent.bugly:crashreport:${Versions.bugly}"

}

/**路由框架*/
object Router {
    // ARouter
    const val arouter = "com.alibaba:arouter-api:${Versions.arouter_api}"
    const val arouterCompiler = "com.alibaba:arouter-compiler:${Versions.arouter_api}"
}

object MaterialDialog {
    const val core = "com.afollestad.material-dialogs:core:${Versions.material_dialog}"
    const val ext_lifecycle =
        "com.afollestad.material-dialogs:lifecycle:${Versions.material_dialog}"
    const val ext_color = "com.afollestad.material-dialogs:color:${Versions.material_dialog}"
    const val ext_datetime = "com.afollestad.material-dialogs:datetime:${Versions.material_dialog}"
    const val ext_bottom_sheet =
        "com.afollestad.material-dialogs:bottomsheets:${Versions.material_dialog}"

    val values = listOf(
        core,
        ext_lifecycle,
        ext_color,
        ext_datetime,
        ext_bottom_sheet
    )
}

//jetpack 相关
object JetpackRely {
    //
    const val fragment_ktx = "androidx.fragment:fragment-ktx:1.3.1"
    const val activity_ktx = "androidx.activity:activity-ktx:1.3.1"

    //～～～～～～～～～～  liveDate  ～～～～～～～～～～～～
    const val livedata = "com.kunminx.archi:unpeek-livedata:4.4.1-beta1"


    //～～～～～～～～～～  lifecycle  ～～～～～～～～～～～～
    const val lifecycle_runtime = "androidx.lifecycle:lifecycle-runtime-ktx:${Versions.lifecycle}"
    const val lifecycle_common = "androidx.lifecycle:lifecycle-common-java8:${Versions.lifecycle}"
    const val lifecycle_service = "androidx.lifecycle:lifecycle-service:${Versions.lifecycle}"
    const val lifecycle_viewmodel = "androidx.lifecycle:lifecycle-viewmodel:${Versions.lifecycle}"
    const val lifecycle_livedata = "androidx.lifecycle:lifecycle-livedata:${Versions.lifecycle}"
    const val lifecycle_process = "androidx.lifecycle:lifecycle-process:${Versions.lifecycle}"

    val lifecycleList = listOf(
        lifecycle_runtime,
        lifecycle_common,
        lifecycle_service,
        lifecycle_viewmodel,
        lifecycle_livedata,
        lifecycle_process
    )

    //～～～～～～～～～～  navigation  ～～～～～～～～～～
    const val navigation_fragment = "androidx.navigation:navigation-fragment-ktx:2.3.5"
    const val navigation_ui_ktx = "androidx.navigation:navigation-ui-ktx:2.3.5"
    val navigation_values = listOf(
        navigation_fragment, navigation_ui_ktx
    )

    //~~~~~~~~~~~~~~~~~~~ Room ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    const val room_runtime="androidx.room:room-runtime:${Versions.room}"
    const val room_compiler="androidx.room:room-compiler:${Versions.room}"
    const val room_rxjava2="androidx.room:room-rxjava2:${Versions.room}"
    const val room_rxjava3="androidx.room:room-rxjava3:${Versions.room}"
    const val room_guava="androidx.room:room-guava:${Versions.room}"
    const val room_paging="androidx.room:room-paging:2.5.0-alpha01"

}

